Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cody Web: Support directory as initial context #5297

Merged
merged 2 commits into from
Aug 22, 2024

Conversation

vovakulikov
Copy link
Contributor

Part of SRCH-940

See the original issue; in the Sourcegraph repo page, it's a common case when you open Cody Web chat from the directory page, so it makes sense to support directories as an initial mention for the chat.

Test plan

  • Check that Cody Web demo resolves proper context with default directory mention (demo already has directory mention by default)

@vovakulikov vovakulikov requested review from thenamankumar and a team August 22, 2024 15:32
@vovakulikov vovakulikov self-assigned this Aug 22, 2024
@@ -104,7 +104,7 @@ export default defineProjectWithDefaults(__dirname, {
assetsDir: '.',
reportCompressedSize: true,
lib: {
formats: ['cjs'],
formats: ['es'],
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change is needed to unblock the svelte Cody Web update.

@@ -10,7 +10,7 @@
},
"main": "dist/index.js",
"types": "dist/lib/index.d.ts",
"sideEffects": false,
"sideEffects": true,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what is this about?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is needed for the proper bundle process on the Sourcegrpah side. When we target to es modules when we bundle/build Cody Web library it's important to specify this that compiler and minifier on Sourcegraph side won't remove unused es imports in Cody Web web-worker.

Copy link
Member

@thenamankumar thenamankumar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Please link this PR when you create one for SG.

@vovakulikov vovakulikov merged commit 5c039ea into main Aug 22, 2024
18 of 19 checks passed
@vovakulikov vovakulikov deleted the vk/support-directory-as-initial-context branch August 22, 2024 16:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants